package edu.sdjzu.exam.dto;

import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;

@Data
public class StudentExamDTO {
    private Long examId;
    private String title;
    private String description;
    private LocalDateTime startTime;
    private LocalDateTime endTime;
    private Integer durationMinutes;
    private Long createdBy;
    private Long courseId;
    private LocalDateTime createdAt;
    private LocalDateTime updatedAt;
    private BigDecimal totalScore;
    private List<StudentExamQuestionDTO> questions;

    @Data
    public static class StudentExamQuestionDTO {
        private Long examQuestionId;
        private Long questionId;
        private Integer questionOrder;
        private BigDecimal score;
        private StudentQuestionDTO question;
    }

    @Data
    public static class StudentQuestionDTO {
        private Long questionId;
        private String content;
        private String questionType;
        private String subject;
        private String difficulty;
        private Long createdBy;
        private Long courseId;
        private LocalDateTime createdAt;
        private LocalDateTime updatedAt;
        private List<StudentQuestionOptionDTO> options;
        // 注意：不包含referenceAnswer字段
    }

    @Data
    public static class StudentQuestionOptionDTO {
        private Long optionId;
        private Long questionId;
        private String content;
        private Integer optionOrder;
        // 注意：不包含isCorrect字段
    }
}